<%@ page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1" %>
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
	<head>		
		<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">		
		<link rel="shortcut icon" href="/resources/favicon.ico" type="image/x-icon"/>
		<link rel="stylesheet" type="text/css" href="/resources/styles.css">
		<title>Homegrown Cuisine - Recipe Detail</title>				
	</head>	
	<body>			
		<h1>Welcome to Homegrown Cuisine</h1>
		<c:set var="recipe" value="${recipe}"/>   
		<a href="./">Home</a><br>
		<div style="background:silver;">			
			<table width="100%" class="datagrid">					
				<tr>
					<th colspan="2">Recipe Details</th>
				</tr>
				<tr>
					<td class="label">Key</td>
					<td class="value"><c:out value="${recipe.key}" /> </td>
				</tr>		
				<tr>
					<td class="label">Title</td>
					<td class="value"><c:out value="${recipe.title}" /></td>
				</tr>
				<tr>
					<td class="label">Author</td>
					<td class="value"><c:out value="${recipe.author}"/></td>
				</tr>
				<tr>
					<td class="label">Ingredients</td>
					<td class="value"><c:out value="${recipe.ingredients}" /></td>
				</tr>
				<tr>
					<td class="label">Preparation Time Hours</td>
					<td class="value"><c:out value="${recipe.preparationTimeHours}" /></td>
				</tr>
				<tr>
					<td class="label">Preparation Time Min</td>
					<td class="value"><c:out value="${recipe.preparationTimeMin}" /></td>
				</tr>
				<tr>
					<td class="label">Preparation Steps</td>
					<td class="value"><c:out value="${recipe.preparationSteps}" /></td>
				</tr>
				<tr>
					<td class="label">Wine Proposal</td>
					<td class="value"><c:out value="${recipe.wineProposal}" /></td>
				</tr>
				<tr>
					<td class="label">Side Dishes</td>
					<td class="value"><c:out value="${recipe.sideDish}" /></td>
				</tr>
				<tr>
					<td class="label">Image</td>
					<td class="value"><img src="recipedetail/image?id=${recipe.key.id}" width=480 height="640" /></td>
				</tr>
				<tr>
					<td class="label">Category</td>
					<td class="value"><c:out value="${recipe.category}"/></td> 
				</tr>
		 		<tr>
					<td class="label">Season</td>
					<td class="value"><c:out value="${recipe.season}"/></td> 
				</tr>
			</table>			
		</div>		
	</body>
</html>